<template>
  <div class="my">
    <van-sticky>
      <div class="top">
        <div class="iconfont icon-shezhi" @click="$router.push('/my/setup')"></div>

        <div class="right">
          <i class="iconfont icon-tongzhi"  @click="$router.push('/Search/tongzhilist')"></i>
          <i class="iconfont icon-zhuanfa" @click="showShare = true"></i>
        </div>
      </div>
    </van-sticky>

    <div class="user">
      <div class="left"><img src="../assets/4.png" alt="" /></div>
      <div class="right">
        <span class="name">Ninja</span>
        <span class="lv">LV.1</span>
        <div class="btn">补全资料 +500经验值</div>
      </div>
    </div>

    <div class="autograph">
      <span class="sex">厨男</span>
      <span class="year">豆龄 0.2岁</span>
      <div class="title">吃货不是在吃就是在去吃的路上，没时间写签名</div>
    </div>

    <div class="items_">
      <div class="item_">
        <div class="num">0</div>
        <div class="fans">关注</div>
      </div>
      <div class="item_">
        <div class="num">0</div>
        <div class="fans">粉丝</div>
      </div>
      <div class="item_">
        <div class="num">0</div>
        <div class="fans">被收藏</div>
      </div>
      <div class="item_">
        <div class="num">0</div>
        <div class="fans">被学做</div>
      </div>
      <div class="item_">
        <div class="num">28</div>
        <div class="fans">经验值</div>
      </div>
    </div>

    <div class="bg">
      <div class="left">
        <div class="iconfont icon-wangguan"></div>
        <div class="rightt">
          <div class="title">尊享vip卡</div>
          <div class="titlee">400节好课免费学 ></div>
        </div>
      </div>
      <div class="right">
        <div class="iconfont icon-yingbi"></div>
        <div class="rightt">
          <div class="title">签到领钱</div>
          <div class="titlee">做任务赢现金 ></div>
        </div>
      </div>
    </div>
    <div class="items">
      <div class="item">
        <div class="iconfont icon-diannao"></div>
        <div class="text">创作者中心</div>
      </div>
      <div class="item">
        <div class="iconfont icon-caogaoxiang"></div>
        <div class="text">草稿箱</div>
      </div>
      <div class="item">
        <div class="iconfont icon-mifan"></div>
        <div class="text">膳食管理</div>
      </div>
      <div class="item">
        <div class="iconfont icon-peitaosheshixiaotubiao_weibolu"></div>
        <div class="text">厨具管理</div>
      </div>
      <div class="item">
        <div class="iconfont icon-zuijin"></div>
        <div class="text">最近浏览</div>
      </div>
    </div>
    <div class="items">
      <div class="item">
        <div class="iconfont icon-gouwudai1"></div>
        <div class="text">采购清单</div>
      </div>
      <div class="item">
        <div class="iconfont icon-dianzishu"></div>
        <div class="text">电子书</div>
      </div>
      <div class="item">
        <div class="iconfont icon-qianbao"></div>
        <div class="text">钱包</div>
      </div>
      <div class="item">
        <div class="iconfont icon-youhuiquan"></div>
        <div class="text">优惠券</div>
      </div>
      <div class="item">
        <div class="iconfont icon-dingdan2"></div>
        <div class="text">订单</div>
      </div>
    </div>

    <van-tabs v-model="active">
      <van-tab title="菜谱">
        <div class="text">要发布点内容才能配得上我吃货的名声</div>
        <div class="btn">+发布菜谱</div>
      </van-tab>
      <van-tab title="笔记">
        <div class="text">发布点内容解锁美食日历</div>
        <div class="btn">+发布笔记</div>
      </van-tab>
    </van-tabs>
    <van-share-sheet v-model="showShare" title=" " :options="options" />
    <footNav> </footNav>
  </div>
</template>

<script>
import footNav from "../components/base/footNav.vue";
import Vue from "vue";
import { ShareSheet } from "vant";
import { Toast } from "vant";
Vue.use(ShareSheet);
export default {
  data() {
    return {
      showShare: false,
      options: [
        [
          { name: "微信", icon: "wechat" },
          { name: "朋友圈", icon: "wechat-moments" },
          { name: "微博", icon: "weibo" },
          { name: "QQ", icon: "qq" },
        ],
      ],
    };
  },
  components: {
    footNav,
  },
  methods: {
    onSelect(option) {
      Toast(option.name);
      this.showShare = false;
    },
  },
};
</script>

<style lang='less'>
.my {
  .top {
    background: #fff;
 
    padding-bottom: 20px;
    padding-top: 30px;

    font-weight: bold;
    display: flex;
    justify-content: space-between;
    align-items: center;
    .iconfont {
      font-size: 20px;
      margin: 0 20px;
    }
    .right {
      i {
        margin-left: 25px;
      }
      .icon-tongzhi{
        margin: 0;
      }
    }
  }
  .user {
    display: flex;
    align-items: center;
    margin: 0 15px;
    margin-bottom: 23px;
    .left {
      width: 75px;
      height: 75px;
      line-height: 7;
      text-align: center;
      border-radius: 50%;
      background: rgb(255, 255, 255);
      margin-right: 18px;
      border: 1px solid #dcdcdc;
      img {
        width: 58px;
        height: 50px;
        border-radius: 50%;
      }
    }
    .right {
      font-size: 15px;
      font-weight: bold;
      .name {
        margin-right: 5px;
      }
      .lv {
        color: #c0a345;
        font-size: 12px;
      }
      .btn {
        margin-top: 10px;
        background: #f6c755;
        border-radius: 25px;
        height: 30px;
        line-height: 30px;
        padding: 0 50px;
      }
    }
  }
  .autograph {
    margin: 0 15px;
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 27px;
    .sex {
      margin-right: 14px;
    }
    .title {
      margin-top: 10px;
      color: #a3a3a3;
    }
  }
  .items_ {
    margin-left: 11px;
    margin-right: 6px;
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    .item_ {
      text-align: center;
      width: 100%;
      font-size: 14px;
      // font-weight: bold;
      color: #9b9b9b;
      .num {
        color: #040404;
        margin-bottom: 5px;
      }
    }
  }
  .bg {
    margin: 0 15px;
    height: 45px;
    // line-height: 45px;
    background: #434343;
    border-radius: 10px;
    display: flex;
    .left {
      display: flex;
      align-items: center;
      margin-left: 15px;
      margin-right: 45px;
      .iconfont {
        font-size: 25px;
        color: #f9db97;
        margin-right: 10px;
      }
      .rightt {
        .title {
          font-size: 15px;
          color: #fae8b9;
        }
        .titlee {
          font-size: 10px;
          color: #fbfbfa;
        }
      }
    }
    .right {
      display: flex;
      align-items: center;
      .iconfont {
        font-size: 30px;
        color: #f9db97;
        margin-right: 10px;
      }
      .rightt {
        .title {
          font-size: 15px;
          color: #fae8b9;
        }
        .titlee {
          font-size: 10px;
          color: #fbfbfa;
        }
      }
    }
  }
  .items {
    margin: 20px 6px 0 11px;
    display: flex;
    justify-content: space-between;

    .item {
      text-align: center;
      width: 100%;
      .iconfont {
        font-size: 25px;
        margin-bottom: 10px;
        // font-weight: bold;
      }
      .icon-Group,
      .icon-yuebing {
        font-weight: inherit;
      }
      .text {
        color: #a2a2a2;
        font-size: 13px;
      }
    }
  }

  .van-tabs {
    margin-top: 30px;
    text-align: center;
    margin-bottom: 95px;
    .text {
      font-size: 12px;
      color: #919191;
      margin: 50px 0 100px 0;
    }
    .btn {
      height: 30px;
      padding: 5px 15px;
      width: 90px;
      line-height: 30px;
      font-weight: bold;
      background: #f3ca4e;
      border-radius: 30px;
      margin: auto;
      color: #060e18;
    }
  }
  .van-tabs__line {
    position: absolute;
    bottom: 20px;
    left: 0;
    z-index: 1;
    width: 20px;
    height: 3px;
    background-color: #f9c341;
    border-radius: 3px;
  }
  .van-tab {
    position: relative;
    display: -webkit-box;
    display: -webkit-flex;
    display: flex;
    -webkit-box-flex: 1;
    -webkit-flex: 1;
    flex: 1;
    -webkit-box-align: center;
    -webkit-align-items: center;
    align-items: center;
    -webkit-box-pack: center;
    -webkit-justify-content: center;
    justify-content: center;
    box-sizing: border-box;
    padding: 0 4px;
    /* color: #646566; */
    font-size: 14px;
    line-height: 20px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
  }
  .van-tab--active {
    font-size: 18px;
    font-weight: bold;
  }
}
</style>